Collision monitoring system

ABSTRACT

Disclosed is an improved system and method for sensing both hard and soft obstructions for a movable panel such as a sunroof. A dual detection scheme is employing that includes an optical sensing as the primary means and electronic sensing of motor current as a secondary means. The secondary means utilizes system empirical precharacterization, fast processing algorithms, motor parameter monitoring including both current sensing and sensorless electronic motor current commutation pulse sensing, and controller memory, to adaptively modify electronic obstacle detection thresholds in real time without the use of templates and cycle averaging techniques.

CROSS REFERENCE TO RELATED APPLICATIONS

[0001] The present application is a continuation-in-part of applicationSer. No. 09/562,986 filed May 1, 2000 which is a continuation-in-part ofapplication Ser. No. 08/736,786 to Boisvert et al. which was filed onOct. 25, 1996, now U.S. Pat. No. 6,064,165 which was a continuation ofU.S. application Ser. No. 08/275,107 to Boisvert et al. which was filedon Jul. 14, 1994 which is a continuation in part of application Ser. No.07/872,190 filed Apr. 22, 1992 to Washeleski et al., now U.S. Pat. No.5,334,876. These related applications are incorporated herein byreference. Applicants also incorporate by reference U.S. Pat. No.5,952,801 to Boisvert et al, which issued Sep. 14, 1999. Thisapplication also claims priority from U.S. Provisional applicationserial No. 60/169,061 filed Dec. 6, 1999 which is also incorporatedherein by reference.

FIELD OF THE INVENTION

[0002] The present invention concerns motor driven actuator controlsystems and methods whereby empirically characterized actuationoperation parameters are subsequently monitored.

BACKGROUND

[0003] National Highway Traffic Safety Administration (NHTSA) Standard118 contains regulations to assure safe operation of power-operatedwindows and roof panels. It establishes requirements for power windowcontrol systems located on the vehicle exterior and for remote controldevices. The purpose of the standard is to reduce the risk of personalinjury that could result if a limb catches between a closing poweroperated window and its window frame. Standard 118 states that maximumallowable obstacle interference force during an automatic closure isless than 100 Newton onto a solid cylinder having a diameter from 4millimeters to 200 millimeters.

[0004] Certain technical difficulties exist with operation of prior artautomatic power window controls. One difficulty is undesirable shutdownof the power window control for causes other than true obstacledetection. Detection of obstacles during startup energization, softobstacle detection, and hard obstacle detection each present technicalchallenges requiring multiple simultaneous obstacle detectiontechniques. Additionally, the gasket area of the window that seals toavoid water seepage into the vehicle presents a difficulty to the designof a power window control, since the window panel encounterssignificantly different resistance to movement in this region. Operationunder varying power supply voltage results in actuator speed variationsthat result in increased obstacle detection thresholds.

SUMMARY OF THE INVENTION

[0005] This invention concerns an improved actuator system that providesfaster operation, more sensitive obstacle detection, faster actuatorstopping with reduced pinch force, and reduced false obstacle detectionall with less costly hardware. This invention has utilization potentialfor diverse automatic powered actuator applications includingpositioning of doors, windows, sliding panels, seats, control pedals,steering wheels, aerodynamic controls, hydrodynamic controls, and muchmore. One exemplary embodiment of primary emphasis for this disclosureconcerns an automatic powered actuator as a motor vehicle sunroof panel.

[0006] An exemplary system built in accordance with one embodiment ofthe invention implements position and speed sensing is via electronicmotor current commutation pulse sensing of the drive motor. Motorcurrent commutation pulse counting detection means and countingcorrection routines provide improved position and speed accuracy.

[0007] In one exemplary embodiment, stored empirical parametercharacterizations and algorithms adaptively modify obstacle detectionthresholds during an ongoing actuation for improved obstacle detectionsensitivity and thresholds resulting in quicker obstacle detection withlower initial force, lower final pinch force and reduced occurrences offalse obstacle detection.

[0008] An exemplary embodiment of the collision sensing system uses amemory for actuation speed measurement, motor current measurement, andcalculations of an ongoing actuation with real time adaptive algorithmsenables real time running adaptive compensation of obstacle detectionthresholds.

BRIEF DESCRIPTIONS OF THE DRAWINGS

[0009]FIG. 1 is a block diagram schematic of the components of anexemplary embodiment of the present invention;

[0010] FIGS. 2A-2D are schematics of circuitry for controlling movementand sensing obstructions of a motor driven panel such as a motor vehiclesunroof;

[0011]FIG. 3A is a plan view depicting an optical sensing system formonitoring an obstruction in the pinch zone of a moving panel such as amotor vehicle sunroof;

[0012]FIG. 3B is a front elevation view of the FIG. 3A optical sensingsystem;

[0013]FIG. 3C is a plan view depicting an optical system with movingoptics for monitoring an obstruction at the leading edge of a movingpanel such as a motor vehicle sunroof;

[0014]FIG. 3D is a front elevation view of the FIG. 3C optical sensingsystem;

[0015]FIG. 3E is a plan view depicting an optical sensing system withmoving optics, flexible optic fiber, remote IR emission, and remote IRdetection for monitoring an obstruction at the leading edge of a movingpanel such as a motor vehicle sunroof;

[0016]FIG. 4 represents typical startup energization characteristics ofmotor current and per speed versus time;

[0017]FIG. 5 represents a simplified example of characteristic steadystate nominal motor operation function versus time or position;

[0018]FIG. 6 represents a simplified example characteristic dynamictransient motor operation function versus time and/or position showingmotor operation function with transients;

[0019]FIG. 7 represents a simplified example characteristic dynamicperiodic cyclic motor operation function versus time and/or positionshowing motor operation function with cyclic disturbances; and

[0020]FIG. 8 is a sequence of measurements taken by a controller duringsuccessive time intervals and operation of a monitored panel drivemotor.

BEST MODE FOR PRACTICING THE INVENTION

[0021]FIG. 1 shows a functional block diagram of an actuator safetyfeedback control system 1 for monitoring and controlling movement of amotor driven panel such as a motor vehicle sunroof. A panel movementcontroller 2 includes a commercially available multipurposemicrocontroller IC (integrated circuit) with internal and/or externalFIFO memory and/or RAM (Random Access Memory) 2 a and ADC(analog-to-digital-converter) 2 b.

[0022] Eight-bit word bytes, eight-bit counters, and eight-bitanalog-to-digital conversions are used with the exemplary controller 2.It should be fully realized, however, that alternative word lengths maybe more appropriate for systems requiring different parameterresolution. Larger word bytes with equivalent ADC resolution enablesgreater resolution for motor current sensing. Likewise, larger wordbytes with higher microcontroller clock speeds enable greater resolutionfor motor per speed sensing plus quicker digital signal processing andalgorithm processing for quicker response time.

[0023] A temperature sensor 3 (which according to the preferredembodiment of the invention is an option) when installed, is driven byand sensed by the controller 2. Temperature sensing allows the panelcontroller 2 to automatically sense vehicle cabin temperature and openor close the sunroof to help maintain a desired range of temperatures.Temperature compensation of actuator obstacle detection thresholds istypically unnecessary.

[0024] An optional rain sensor 4 can be both driven by and sensed by themicrocontroller 2. Automatic closing of the sunroof panel occurs whenthe sensor is wet. Subsequently, the sunroof panel can be opened wheneither falling rain has stopped for some time duration or when the rainhas evaporated to some extent.

[0025] Manual switch inputs 5 are the means by which operator control ofthe system occurs.

[0026] Limit switch inputs 6 indicate to the control system suchphysical inputs as HOME position, VENT/NOT OPEN Quadrant Switch, and endof panel movement. Limit switch signals indicate where microcontrollerencoder pulse counter registers are set or reset representative ofspecific panel position(s).

[0027] Motor drive outputs 7 a and 7 b control whether the motor drivesthe panel in the forward or the reverse direction. When neither theforward nor the reverse direction are driven, the motor drive terminalsare electrically shorted together, possibly via a circuit node such asCOMMON, resulting in an electrical loading and thus a dynamic brakingeffect.

[0028] Motor plugging drive, which is the application of reverse drivepolarity while a motor is still rotating, is an optional method of morequickly stopping the motor, but has been unnecessary for use with thepreferred embodiment of the sunroof panel controller due to satisfactoryperformance taught by this disclosure. Very large motor pluggingcurrents are often undesirable because they can easily exceed typicalmaximum stalled rotor currents producing undesired motor heating inlarge applications. Such high motor plugging currents can be detrimentalto the life and reliability of electromechanical relay contacts andsolid state switches used to switch motor operating currents. High motorplugging currents can also cause undesirable transients, trip breakers,and blow fuses in a power supply system.

[0029] Application of brakes and/or clutches is also unnecessary withthe automotive sunroof system due to the improved real time obstacledetection performance taught by this disclosure.

[0030] Optical Obstacle Detection

[0031] Obstacle detection by actual physical contact and/or pinch forcewith human subjects is somewhat unnerving to some individuals. Forimproved system safety and user comfort, the preferred system utilizesnon-contact detection of obstacles in the path of the moving panel. Ofvarious technologies by which it is possible to sense an obstaclewithout physical contact, IR (infrared) emission with transmissioninterruption mode detection is preferred. IR emitting diodes and/or IRlaser diodes are the two preferred IR emission sources. IR photodiodesand/or IR phototransistors are the two preferred IR detection means.Optical obstacle detection senses and enables stopping of the actuatormovement prior to significant applied pinch force and possibly prior toactual physical contact with a subject. In unusual light conditions,explained below, optical sensing means becomes temporarily ineffective,thus obstacle detection via motor current sensing or current sensing andspeed sensing means becomes the remaining reliable backup method ofdetecting an obstacle.

[0032] Of two preferred configurations utilized for implementing IRtransmission interruption mode of obstacle detection, the first is useof at least one emitter and at least one detector sensing at leastacross the pinch zone in close proximity to an end of travel region of asunroof. As shown in FIGS. 3A and 3B, at least one IR emitter 100 and atleast one IR detector 102 are separated from each other by a sunroofpinch zone 104. In an exemplary embodiment of the invention, optosensing of obstructions is across and in relatively close proximity to apinch zone near the end of travel region of a sunroof. The depictions inFIGS. 3A and 3B do not show the entire region between emitter anddetector but it is appreciated that a gap G between emitter and detectoris on the order of the width of the moving sunroof. In this preferredembodiment, cabling 108 passes to the region of the detector 102 aroundthe end of the sunroof liner in the region of the end of the sunrooftravel. The detector and emitter are fixed to the sunroof liner and donot move. Implementation of this fixed configuration is simplified bylack of moving components, although the sunroof may have to push theobstacle into a sensing field between the emitter 100 and the detector102. Thus, although the sensing means is non-contact, the sunroof canstill contact the obstacle.

[0033] Of two preferred configurations utilized for implementing IRtransmission interruption obstacle detection, the second is use of atleast one emitter and at least one detector sensing at least immediatelyahead of the front moving edge of the moving portion of a sunroof. Asshown in FIGS. 3C and 3D, at least one IR emitter 100 and at least oneIR detector 102 are separated proximal a front moving edge of a sunroof103. In an exemplary embodiment of the invention, opto-sensing ofobstructions is across and in relatively close proximity to a front edge105 of the sunroof 103. The depictions in FIGS. 3C and 3D show theentire region between emitter and detector for which a gap G, betweenemitter and detector, is on the order of the width of the movingsunroof. In this preferred embodiment, flexible flat circuitry 107passes to the emitter 100 and the detector 102 of the moving panel orwindow to the region of the front moving edge. Alternate means to supplyelectrical signal and/or power to the moving opto-electronic componentsincludes means such as electrical contact brushes cooperating withconductive traces on the moving panel. Power and signal are optionallyboth transmitted over the same conductors. FIG. 3E shows an alternativemeans to supply IR emission to receive IR detection from the front edgeof the moving panel via flexible moving optic fiber 303 means connectedwith components 300, 302 that respectively emit IR and detect IRsignals. IR optical fibers are terminated at each end to opticalcomponents 304, 305 that perform collimating, reflecting, and focusingrequirements. The structure depicted in FIGS. 3A-3E make it possible tosense obstructions with no physical obstacle contact regardless of theposition of the moving sunroof.

[0034] Alternate, non-preferred means of obstacle detection includesensing back reflection from a reflective surface of radiation emittedfrom an emitter, electric field sensing of proximal material dielectricproperties, and magnetic field sensing of proximal material inductiveproperties.

[0035] Various techniques improve the operation and reliability ofnon-contact optical detection sensing. In accordance with an exemplaryembodiment of the present invention, the IR emitter 100 is driven with aduty cycle and frequency. One typical automobile sunroof applicationuses 20% duty cycle at 500 Hz IR emitter drive synchronized with IRdetector sensing. Pulsed drive allows the IR emitter 100 to be drivenharder during its on time at a low average power. This harder driveyields improved signal-to-noise for IR sensing by the IR detector. TheIR detector circuit synchronously compares the IR signal detected duringIR emitter on times with IR emitter off times to determine ambient IRlevels for drive and signal compensation purposes. This allows the IRemitter to IR detector optical coupling to be determined with a level ofaccuracy and reliability using closed loop feedback techniques.

[0036] Automatic gain feedback control techniques maintain the level ofthe IR emitter drive and/or the gain of the IR detector circuit so thatoptical coupling is above minimum desirable values. Such automatic gaincompensates, within certain limitations, factors including decrease inIR emitter output over accumulated time at temperature, IR emitteroutput temperature coefficient, dirt and haze fouling optic components,and high ambient IR levels.

[0037] Highly directional IR optical lenses and/or aligned polarizedfilters on both the IR emitter and IR detector maintain better opticalcoupling and reduce the effects of ambient IR and reflected IR fromother directions. Location of the IR detector in a physical recessfurther reduces the possibility of extraneous IR “noise” from affectingthe optical coupling.

[0038] Despite various means to reduce the possibility of excessextraneous IR from being detected, certain conditions occur that mayallow very high levels of direct and/or reflected sunlight to be “seen”by the detector. Sun IR power levels can saturate the detector outputsignal level so that obstacle blockage of the pulsed IR emitter signalsis not reliably sensed. Under such unusual “white out” circumstances,the IR optical system is disabled by the panel controller 2 until thesunroof actuator is nearly closed, at which position ambient IR noise isshielded by the sunroof. Thus, the complete emitter-detector IR couplingis made more reliable for the last movement of pinch point closure.Complete body blockage of the IR coupling path between the emitter anddetector is not a “white out” condition, although if the body isblocking both ambient IR and emitted IR signal at the detector, a “blackout” condition is interpreted as an obstacle detection.

[0039] Although the IR obstacle detection means may be temporarily foundto be unreliable by high ambient levels of IR, the disclosed sensing ofhard and/or soft obstacles by motor current monitoring is always activeas a redundant obstacle detection means.

[0040] Detailed Schematic

[0041] The controller schematic shown in FIGS. 2A-2D implementscollision sensing in one form by activating a light emitting diode 100 awhich emits at periodic intervals. In the event the infra red radiationis not sensed by a photo transistor detector 102 a, the controller 2assumes an obstruction and deactivates the sunroof motor M. There isalso a redundant and more reliable obstacle detection means fordetecting obstacles based upon sensed motor operation parameters.

[0042] The preferred controller 2 is an Atmel 8 Bit microprocessorhaving 8 Kilobytes of ROM and includes programming inputs 106 which canbe coupled to an external data source and used to reprogram themicroprocessor controller 2. User controlled inputs 5 a, 5 b are coupledto user activated switches which are activated to control movement ofthe sunroof. The inputs are similar to now issued U.S. Pat. No.5,952,801 to Boisvert et al, which describes the functionality of thoseinputs. Limit switch outputs 5 c, 5 d, 5 e are also monitored by thecontroller 2 and used to control activation of the sunroof drive motor.

[0043] The schematic depicts a clock oscillator 110 for providing aclock signal of 6 MHZ for driving the microprocessor controller 2. Tothe upper left of the oscillator is a decoupling capacitor circuit 112for decoupling a VCC power signal to the microprocessor.

[0044] The circuitry depicted in FIG. 2B provides power signals inresponse to input of a high signal at the ignition input 114. When theignition input goes high, this signal passes through a diode 116 to thebase input 118 of a transistor 120 which turns on. When the transistor120 turns on, a regulated output of 5 volts (VCC) is provided by avoltage regulator 122 in the upper right hand corner of FIG. 2B. Avoltage input to the voltage regulator 122 is derived from two batteryinputs 124, 126 coupled through a filtering and reverse polarityprotection circuit 130. Immediately above the positive battery input 124is a relay output 131 which provides a signal one diode drop less thanbattery voltage VBAT which powers the relay coils 132, 134 (FIG. 2D) foractivating the motor.

[0045] The circuitry of FIGS. 2A-2D includes a number of operationalamplifiers which require higher voltage than the five volt VCC logiccircuitry power signal. At the extreme right hand side of the schematicof FIG. 2B are two transistors 136, 138 one of which includes a base 140coupled to an output 142 from the microprocessor controller 2. Thesecond transistor has its collector coupled to the battery and an outputon the emitter designated V-SW. When the microprocessor turns on thetransistor 138, the V-SW output goes to battery voltage. The V-SW outputis connected to a voltage regulator (not shown) which generates a DCsignal that is supplied throughout the circuit for operation of thevarious operational amplifiers.

[0046] The microprocessor controller 2 also has two motor controloutputs 150, 152 which control two switching transistors 154, 156, whichin turn energize two relay coils 132, 134. The relay coils have contacts162, 164 coupled across the motor M for energizing the motor windingswith a battery voltage VBAT. One or the other of the transistors must beturned on in order to activate the motor. When one of the twotransistors is on, the motor M rotates to provide output power at anoutput shaft for moving the sunroof or other panel along a path oftravel in one direction. To change the direction of the motor rotation,the first transistor is turned off and the second activated. The motorused to drive the sunroof panel back and forth along its path of travelin the exemplary embodiment of the present invention is a DC motor.

[0047]FIG. 2C depicts a circuit 180 for monitoring light emitting diodesignals. A light emitting diode 100 a has an anode connection 181coupled to the V-switched signal and the cathode is coupled through aswitching transistor 182 to a microprocessor output 183. Themicroprocessor outputs a 500 hertz signal at this output 183 having a20% duty cycle to the base input of the transistor. When the transistorturns on, the LED cathode is pulled low, causing the light emittingdiode 100 a to emit IR radiation. Under microprocessor control, thelight emitting diode produces a 500 hertz output which is sensed by aphoto detector 102 a. As the light emitting diode pulses on and off at500 hertz, the photo detector responds to this input. When current flowsin the photo detector, a voltage drop is produced across a voltagedivider 184 having an output coupled to an operational amplifier 186.When current flows in the photo detector in response to receipt of alight signal the voltage divider raises the voltage at the invertinginput 188 to the amplifier 186. The non-inverting input to thisamplifier is maintained at 2.5 volts by a regulated voltage divider 188.The operational amplifier 186 and a second operational amplifier 190define two inverting amplifiers which in combination produce an outputsignal of 500 hertz. With no signal appearing at the photo detector, anoutput 192 from the operational amplifier 190 is 2.5 volts. This signalis coupled to the microprocessor controller 2. In response to receipt ofthe photo detector signal, this signal oscillates and this oscillatingsignal in turn is sensed by the microprocessor.

[0048] The microprocessor controller 2 has two inputs 192, 194 thatprovide input signals to a comparator implemented by the microprocessorcontroller. As the state of the comparator changes, internalmicroprocessor interrupts are generated which cause the microprocessorto execute certain functions. The first input 192 is derived from theoutput from the phototransistor 102 a. The second input 194 to thecomparator is a 3.3 volt signal generated by a voltage divider 195.

[0049] Motor Current Monitoring

[0050] A motor current monitoring circuit is depicted in FIG. 2D andincludes a number of operational amplifiers 200-203 coupled to a currentmeasuring resistor 210 in the lower right hand portion of the circuitdiagram. This current measuring resistor is coupled to the operationalamplifier 200 configured as a differential amplifier through a secondresistor 211. An output 212 from this differential amplifier is a signalproportional to the current through the motor windings which has beenamplified by a factor of about four. The output from this amplifierpasses to a second gain of 3 amplifier 201 to an output 214 coupled tothe microprocessor controller through a resistor 215. This signal ismonitored by the microprocessor and converted by an A to D conversion toa digital value directly related to motor current.

[0051] An input 220 to the second pair of operational amplifiers 202,203 is either an output from the first differential amplifier 200 or thesecond gain of 3 amplifier 201 depending upon whether a resistor 222 isinstalled in the circuit. One but not both of the resistors 222, 223 areinstalled in the circuit.

[0052] The changing signal output from the resistor 210 is coupled to aninverting input of an AC coupled amplifier and produces an output signal226 to the microprocessor controller 2 which changes with motor currentand more particularly as the commutator brushes pass over the motorarmature commutation segments, the signal changes to form a sequence ofpulses. The amplifier 203 is a level shifting amplifier which reducesthe gain of the first amplifier depending upon sensed conditions. Whenthe motor first is activated a large current rush occurs due to the factthat the motor is stalled. This large current rush changes the output ofthe amplifier 203 thereby producing meaningful data even in a highcurrent situation. As the current changes, the output of this topamplifier 203 varies to allow meaningful data to be supplied to themicroprocessor regardless of absolute values of motor current.

[0053] The signal at the microprocessor is a analog signal having theripple component as the motor rotates. This signal is in turninterpreted by the microprocessor controller 2 which generates valuesdirectly related to motor speed based upon the sensing and counting ofthese pulses. Additionally, the value changes in such a way that theslope can be monitored so that the microprocessor can use digital signalprocessing techniques on the input signal to determine a stalled motorcondition representing an obstacle.

[0054] At motor startup the large currents that are experienced make itdifficult to sense object collisions with the moving window or panel. Inaccordance with one embodiment of the invention the controller maintainsa position of the leading edge of the window or panel and during certainstartups will alter a startup sequence.

[0055] If the window or panel is stopped in a region where entrapment ismore likely, such as in the last portion of travel just before closingof the window or panel, the motor is energized to move the window ashort distance away from its stopped position away from the closedposition. A controller which controls the motor then reverses motorrotation sense to move the window or panel in a direction to close thewindow or panel. Stated another way, the controller causes the motor tomove the panel or window in a direction to open the window or panel andthen change motor energization to close the window or panel. Thisprocess avoids difficult to sense obstacle detection during the initialstart up period of motor operation.

[0056] The region of the window or panel seal is a region of increasedmotor load. In this region, in accordance with one embodiment of theinvention, in response to a detection of an obstacle, the controllerimmediately causes motor deenergization, followed by quick reversal ofactuation drive for a short distance (for example one inch). Thecontroller then performs an immediate re-energization in the initialdirection so that a more sensitive and accurate obstacle detectionprocess can be performed. The controller can either determine that theinitial obstacle detection was false due to actuator startup conditions,and thus continue to power the motor or else verify the obstaclepresence that was previously detected and cause the appropriate responseof stopping or alternatively stopping and reversing the window or panelfor a short distance.

[0057] Measured Motor Parameters—DC Current Sensing

[0058] By monitoring the two inputs 216, 226, the microprocessorcontroller 2 monitors the motor current from which the controller 2determines both sunroof incremental position and speed. Sensed motorcurrent is always positive regardless of motor drive polarity androtation direction. For either condition of drive polarity thenon-energized side of the motor is connected to COMMON through the lowvalue current sensing resistor 210 to produce a positive analog signalvoltage directly proportionate to the motor current.

[0059] This motor current signal is converted via hardware and/orsoftware to a filtered signal and scaled by a fixed or optionallyvariable reference voltage to produce a value less than a determinedmaximum value where the following definition applies: CUR={sensed motorcurrent analog-to-digital-converted and scaled to engineering units},where the analog value for motor current is converted to eight-bitdigital resolution via an eight-bit ADC (analog-to-digital converter)within the microprocessor controller 2. Eight bit resolution in acontroller counter for CUR yields an absolute count range of 0≦CUR≦255,where a maximum analog reference voltage is provided to the ADC to setthe anticipated maximum possible motor current limit value representedby a reference value 255.

[0060] A preferred means to increase sensed motor current resolution andthus improve obstacle detection sensitivity is to adaptively adjust thereference voltage (set=value of 255 representative of full scale) and/orthe sensed motor current signal during times of relatively low currentoperation, returning to the highest scale during starting energization,end-stall detection, and as necessary for obstruction detection. Forthis eight-bit example, at least one bit of current measurementresolution can be gained during low current operation by decreasing thereference voltage by such means as a variable attenuation network and/orby scaling up the motor current signal by such means as a variable gainamplifier.

[0061] Analog motor current signal is lowpass filtered to remove noisesfrom motor current commutation and switching transients to produce afast running average analog drive current signal to the microcontrollerrepresentative of motor torque load conditions. This voltage signal isconverted to a scaled digital value by the microprocessor. For example,normal steady operation of the motor at low battery voltage causes thecontroller to register a digital value of approximately 80 of full scale255, whereas startup energization at high battery voltage will result ina peak digital value of approximately 240 of full scale 255.

[0062] Measured Motor Parameters—AC Current Sensing

[0063] Typical DC brush motor current signals also have inherentwaveform AC ripples due to rotor current commutation. These motorcurrent pulses directly relate to incremental rotation of the motorshaft and since gears and/or mechanical drive linkages link the shaft tothe moving window or panel, directly relate to incremental change ofposition of the actuator. The relationship of motor current commutationpulses to actuator incremental motion is not necessarily a linearcorrespondence.

[0064] Motor current analog signal can be AC coupled, bandpass filtered,amplified, and compared with a threshold to produce a digital signal viaan input representative of motor current commutation signals.Alternatively, motor current commutation signals can be directly sensedfrom the motor current signal via ADC and digital signal processingbandpass filtering having sufficient resolution to accurately measurethe relatively lower amplitude waveforms characteristic of motor currentcommutation pulses.

[0065] Various alternative and more expensive incremental encoder,absolute encoder, and resolver means can produce similar signalsrepresentative of incremental or absolute motor rotor position.

[0066] A parameter monitored by the controller, indicated by a variable,PP, has generic units of time per fixed increment of motor rotation ortime per distance which is defined as: PP={integer number ofmicrocontroller clock cycles per incremental motor encoder pulseperiod}, alternatively referred to as inverse speed or per speed.Eight-bit resolution in an integer counter for PP yields an absoluterange of 0≦PP≦255.

[0067] An input from a resistor network provides a reference voltage (inthe disclosed design about 2.5 volts) to an operational amplifierconfigured as a comparator. Each time the motor current commutates agenerated spike is transmitted through a coupling capacitor to thiscomparator to “square up” the output waveform for input to themicroprocessor controller. The microprocessor counts the number ofmicrocontroller clock pulses between adjacent motor current commutationpulse signals as an indication of pulse period (PP), which is inverselyproportionate to motor speed.

[0068] As an example, a relatively low count of 72 clock cycles perincremental motor encoder pulse period is representative of typicalsteady operation at maximum motor power supply voltage under lightloading conditions whereas the count of 240 clock cycles per encoderpulse period is representative of typical transient startup energizationacceleration at minimum motor power supply voltage under heavy loadingconditions.

[0069] As an alternative to a presently preferred current sensingprocess, other means of determining motor speed are contemplated.Alternate speed sensing technologies include monitoring changes in amagnetic field and converting such changes to a speed of movement.Non-contact sensors for such monitoring include: Hall effect,magnetoresistive, magnetodiode, magnetotransistor, Wiegand effect, andvariable reluctance; capacitive; and optical sensors. Such encoders arecontemplated in U.S. Pat. No. 5,334,876, FIG. 5 which depicts pulsesproduced by a motor shaft encoder that monitors position, speed anddirection of travel of a window or panel.

[0070] In accordance with an alternative embodiment of the invention,reflective and blocking sensing; generated inductive magnetic fields:ECKO (eddy current killed oscillator), variable inductor, and variabletransformer; and film resistor can be used to monitor window or panelmovement.

[0071] Position Accuracy

[0072] Motor current commutation pulses occur at generally regularintervals over the travel path of the panel. One representative vehiclesunroof has approximately 3000 commutation pulses over the fullactuation range of the full open to the full CLOSED positions of thesunroof.

[0073] Back extrapolation of decreasing pulse periods upon startupindicates the typical loss of approximately one sensed pulse upon motorenergization due to the excessive time duration of the first pulse. Thislost pulse is either added or subtracted, depending upon direction ofenergization, to or from the actuator position counter register toincrease incremental position detection accuracy.

[0074] Weak and/or missing motor pole signals, due to a faulty coiland/or commutator segment, are detected via software algorithms thatcall automatic compensation algorithms to maintain a corrected positioncounter register value. Therefore, missed motor current commutationpulses ostensibly representative of motor deceleration magnitude beyondempirically-determined limits are pulse simulated for accuraterepresentation of motor speed and actuator position.

[0075] Extraneous pulses representative of motor acceleration beyondempirically-determined maximums are deleted from processing to maintainaccurate representation of motor speed and actuator position. Adaptingparameters for a DSP bandpass filter algorithm, based upon motor currentand speed, enable improved motor current commutation pulse-sensingsignal-to-noise ratios that result in improved accuracy for incrementalposition and speed sensing and ultimately in improved obstacle detectionaccuracy and sensitivity.

[0076] Minor corrections are made to a position counter register basedupon empirical determinations of numbers of motor current commutationpulses missed due to inertial motion after motor de-energization. Thisnumber of missed pulses is based upon the speed of the motor dueprimarily to the monitored power supply voltage. To reduce errors inthis inertial correction term, consistent motor speeds and thusconsistent number of missed pulses are achieved at motor de-energizationby energization of the motor for no less than a minimum time duration inresponse to even a very brief actuation of the manual motor energizationswitch. Furthermore, software debouncing of the manual switch contactdeglitches the switch outputs at the microcontroller inputs by requiringthe switch contacts be sensed for some minimum time to be considered asa valid control input. Excepting abnormal circumstances such a powerloss and/or obstruction detection, activation of the manual motorenergization switch for more than the debounce time will result in motorenergization for at least a minimum amount of time, thus providingsufficient time to achieve a relatively consistent speed and also arelatively consistent number of missed pulses after de-energization.

[0077] Position Sensing & Alternatives

[0078] By counting motor current commutation pulses as an incrementalencoder, the microcontroller maintains a representation of actuatorposition by upcounting or downcounting a position count register basedupon whether the motor is being energized in a clockwise orcounterclockwise direction. Limit switch inputs and/or end-of-travelstall current indications indicate where the microcontroller positioncounter register is either SET or RESET.

[0079] This method of position sensing is significantly simpler and lesscostly than alternate well-known methods of sensing position usingspecialized sensors such as incremental encoders, absolute encoders, andresolvers. Improvements provided by adaptive DSP bandpass filtersincrease the signal-to-noise and performance accuracy of this sensorlesselectronic position encoding method and means to render it nowtechnically viable for this implementation.

[0080] Alternate position-sensing technologies include permanent magnetfields: Hall effect, magnetoresistive, magnetodiode, magnetotransistor,Wiegand effect, and variable reluctance; capacitive; optical: Reflectiveand blocking; generated inductive magnetic fields: ECKO (eddy currentkilled oscillator), variable inductor, and variable transformer; andfilm resistor.

[0081] No Template Calibration—Simple Position & Range Learning

[0082] Upon powerup, the calibration and/or learning of characteristiccurrent and/or speed versus position may not be necessary. In accordancewith certain embodiments of the invention, the only required learning isthe absolute position of the actuator from a position input so that anincremental position counter can be either SET or RESET. This trueposition can be provided by such means as a limit switch, a Hall-effectswitch at a known actuator position, and/or by sensing motor stallconditions at the ends of travel. Resetting the absolute positioncounter is necessary with some embodiments that sense motor commutationpulses for incremental position encoding. Alternatively, the use of amore expensive absolute encoders having no such incremental positioncounter and requiring no such resetting is a performance versus costengineering design tradeoff decision. By measuring the position of theroof through the sensor on the motor, the full open and close positionscan be determined without the need of additional limit switches orsensors to determine end-of-travel. Also, the true position can bedetermined by the end-of-travel by the current of the motor, or thepreferred method is to detect no position movements through the motorposition sensor and detect end-of-travel and therefore stall. Thecompensation for the window sizes and travels can be pre-programmed viamemory locations at the factory or it can be programmed in a training ofinstallation mode thus eliminating the need for additional end-of-travelswitches for home positions.

[0083] For certain cases the sunroof controller can be used with morethan one type of sunroof, therefore calibration is really a misnomer forwhat amounts to determining which type of sunroof mechanism is beingcontrolled by learning the characteristic range of allowable motion ofthe cooperating mechanism, as well as the actuator position. Thecalibration step need only be performed the first time power is appliedto the circuit, or if the physical characteristics of the sunroofchange. Until calibration is performed, a automatic operation expressmode movement feature is inhibited.

[0084] Recalibration can be initiated at any time the user feels thatthe control circuit is not performing as it should and must always bedone if either the controller 2 or the sunroof is changed. The size ofthe roof is recorded in the EEPROM as well as an identification wordflag to enable sunroof operation in the express mode. The position ofthe sunroof is recorded in the EEPROM each time the sunroof is stoppedfrom moving. This is done to guarantee that in the case of a power downsituation, the current position of the sunroof is always known. If atany time the position is considered to be unknown, the express mode isdisabled until the next time the sunroof is moved to the fully CLOSED orhome position.

[0085] The calibration learning of the movement range and position ofthe sunroof are learned and recorded as follows. The ignition is turnedOFF and within five seconds the OPEN switch is pressed and the ignitionis switched ON. The controller 2 attempts to find the HOME or PARKposition then proceeds to find the limit of the open area or thesunroof, i.e. the fully open position. When a stall condition is sensedthe size of the sunroof open area (by count of motor encoder pulses) isrecorded and the controller reverses the direction toward the PARKposition. The controller then finds the limit of the vent area bydriving the sunroof toward the full VENT position until a stallcondition is sensed. A stall condition is determined whenanalog-to-digital converted motor current is equal to or greater to 180on the unitless current scale ranging from 0 to 255. If it is notpossible to perform the calibration due to a failure to find the parkposition, no information is recorded and the sunroof express mode(automatic operation) is disabled.

[0086] Soft Stop

[0087] High position sensing resolution and accuracy enable theactuation system to anticipate the mechanical limit and thus deenergizethe motor drive just prior to the actuator hitting its hard stop limit.This saves wear and tear on the mechanism as well as aids in maintaininghigh motor commutation pulse sensing accuracy. Mechanical “windup” ofactuator drive components is significantly reduced by deenergizing andthus stopping the actuator before the torque becomes unnecessarilyexcessive. Reduction of mechanical windup further improves theconsistency of the motor current commutation pulse train of a subsequentmotor energization, thus enabling both improved capability of obstacledetection at startup and quicker obstacle detection thresholdadaptation. Utilization of motor current commutation pulse sensing as anincremental encoder is enhanced in both speed and position accuracy byreduction of pulse sensing errors associated with windup relaxation anderratic motor pulse train upon startup.

[0088] Soft stop also limits high values of end-of-travel motor current,thus enabling improved current sensing resolution by use of a lower ADCmotor current reference value that is significantly closer to normaloperating value than to higher stall value. High position sensingaccuracy enables improved position-related determination of critical andfast-changing obstacle detection thresholds. High position sensingaccuracy also enables accurate anticipation of increased motor loadingdue to the elastomeric environmental seal near the closing of the panel,thus obstacle detection thresholds are appropriately increased as afunction of position.

[0089] Digital Signal Processing

[0090] Motor current is sensed by preferred DSP techniques that providelowpass software filtering of the motor current signal to filter outelectrical noises, especially the undesirable frequency rangescharacteristic of commutation pulses, switching transients, pulse drivetransients, and drive transients.

[0091] Motor current commutation pulses are sensed by preferred DSPtechniques that provide bandpass software filtering of the motor currentsignal to highpass filter out the DC motor current signal and to lowpassfilter out electrical noises and especially the undesirable frequencyranges characteristic of pulse width drive transients, when applicable.

[0092] Additionally, adaptive DSP algorithms modify the obstacledetection thresholds in real time response to actual monitored motoroperation parameters. A static shift in motor current and/or speed willresult in a related shift in obstacle detection threshold. A transientdynamic motor current and/or speed will result in a related shift inobstacle detection threshold. Sensed periodic cyclical dynamic motorcurrent and/or speed will result in a related periodic cyclical obstacledetection threshold.

[0093] Advantages of DSP versus hardware implementation as describedabove include smaller circuit size, fewer components, lower cost, lowermass, and especially ability to adapt filter algorithms for pulsedetection thresholds during operation to improve performancecharacteristics.

[0094] Variable Load Parameters—Adaptive Obstacle Detection Threshold

[0095] With the sunroof panel automatic powered actuator system, normalvehicle inside-to-outside relative pressure differences and/or windbuffeting can cause respective static, periodic dynamic, and/ortransient dynamic variations in the effective actuator motor loading andthus in the motor current that is compensated for by algorithms foradaptive obstacle detection thresholds. Increasing vehicle wind speedand/or operation of forced vehicle ventilation can produce staticpressure differences that increase the load on the sunroof panel motorduring operation. Increasing vehicle wind speed and/or externalconditions can produce cyclical wind buffeting conditions thatcorrespondingly cyclically alters the motor loading. Amplitude andfrequency of cyclical buffeting as fluid vortices is a function ofrelative fluid velocity. In certain circumstances, there is arelationship between cyclical wind buffeting and static differential airpressure. Obstacle detection thresholds are actively modified withincreasing vehicle air speed and with increasing wind buffeting toreduce false obstacle detection. It is anticipated that informationabout the vehicle speed and/or direction can provide value to thesunroof application by correlation with characteristic loading of thevehicle sunroof and/or window operation.

[0096] Unique software algorithms enable characteristic determination ofreal time actuator operation load categorized as startup transient,nominal, static variable, periodic dynamic variable, transient dynamic,soft obstacle, and hard obstacle. Nominal load is the characteristicmotor current and speed as empirically pre-characterized for theactuator. Static variable represents a steady factor of the nominal loadby which the ongoing nominal actuation is correspondingly factored up ordown. Transient dynamic load represents temporary load magnitudeexcursion terms by which the ongoing nominal actuation parameter isaltered. Periodic dynamic is a cyclical load term by which the ongoingnominal actuation is cyclically loaded with a regular period andamplitude.

[0097] FIGS. 5-7 show simplified examples of how DSP is applied in realtime to alter and reduce obstacle detection function thresholds forincreased obstacle detection sensitivity tolerances. The inventiveobstacle detection function threshold adaptively responds viasuperposition of individual responses to various simultaneous types ofload disturbance variables herein described.

[0098]FIG. 5 shows an example of a simplified case of a typical obstacledetection threshold based on template technology versus the adaptiveobstacle detection function threshold of the present invention. Therelatively large and fixed obstacle detection threshold accommodates thethree types of system load variables described above. Adaptive obstacledetection achieves comparatively lower threshold values with highersensitivity than fixed threshold systems by virtue of its ability toadapt to various types of system load variables.

[0099]FIG. 6 shows an example of a simplified case of a DSP adapting theobstacle detection function threshold in real time to accommodatedynamic load shifts. Note that the adaptive threshold tracks the motoroperation function with intentional adaptive response delay time andslew rate. The degenerate case of a static load shift is not shown,although somewhat similar to FIG. 6. A comparatively lower thresholdvalue and higher sensitivity is achieved by virtue of the ability toadapt to various types of system load variables.

[0100]FIG. 7 shows an example of a simplified case of inventive DSPadapting the obstacle detection function threshold in real time toaccommodate periodic cyclic dynamic load variations. Initially, beforeperiodicity is ascertained, the adaptive response delay time of FIG. 6prevails. Upon a determination that the disturbance is strictlyperiodic, as with a bad gear tooth, after perhaps three cycles, theadaptive response delay time delay time is reduced to more accuratelytrack the known periodicity of the cyclic disturbance. A comparativelylower threshold value and thus higher sensitivity is provided by theability to adapt to various types of system load variables. Note thatafter cyclical periodicity of the disturbance is established, thenormally lagging response of the adaptive threshold obstacle detectionfunction becomes predictive so the periodicity of the dynamic responseof the adaptive threshold obstacle detection function becomes in phasewith the related dynamic disturbance of the motor operation function.Thus, the adaptive threshold more closely tracks actual motor operationfunction. The net result is obstacle detection with greater sensitivityto real obstacles with reduced occurrences of false obstacle detection.

[0101] The engineered characteristic response time, slew rate, andfrequency response of the real time adaptive obstacle detectionthreshold algorithm must respond in a manner significantly less than 180degrees out of phase with anticipated cyclical load variables, yet notso fast as to interfere with either hard and/or soft obstacle detectionalgorithms. These adaptive threshold response constraints effectivelylimit how fast the real time adaptive obstacle detection functionthreshold is allowed to change in response to changes in load variablethat are ascertained to be not caused by hard or soft obstacleinterference. It is important to see that the real time adaptiveobstacle detection function threshold is equal or lower than the fixedobstacle detection threshold. Lower obstacle detection functionthresholds produce more sensitive obstacle detection, faster obstacledetection, faster actuator deenergization, faster actuator stopping, andlower peak obstacle force at final stopping position.

[0102] Reduced Actuation Speed

[0103] Circuitry disclosed in U.S. Pat. No. 5,334,876 uses a PWM (pulsewidth modulated) activation of the motor windings of a direct currentmotor to control and/or regulate the speed of motor output shaftrotation as the motor opens or closes the window or panel. The presentsystem preferably applies full battery voltage of a motor vehicle acrossthe motor to drive actuator panel motion. As the motor controllerindustry learns to meet obstacle detection anti-pinch force regulations,it is fully anticipated that allowable forces might be lowered, possiblyresulting in the necessity to use motor drive speed-reducing techniquesto enable full regulatory compliance.

[0104] Typical applications of drive power to a motor include full powersupply voltage, fixed duty cycle pulse drive, PWM (pulse widthmodulation) to regulate average motor speed and/or acceleration, pulserepetition modulation to regulate average motor speed and/oracceleration, linear drive of a fixed fraction of the full power supplyvoltage, linear drive of a fixed voltage, controlled linear drive toregulate average motor speed and/or acceleration, and phase angleswitching control for AC motor applications. Switching transients arereduced and RFI/EMC is improved for any of the above switchmode methodsof motor drive by filtering the drive output and/or controlling the slewrate of turn on and/or turn off of the motor drive power.

[0105] Relays and power contactors are typically utilized for relativelyslow power control applications such as for switching on/off and forswitching energization between forward and reverse. Solid state switchesare typically utilized for relatively fast power control switchingapplications. Solid state linear drive components typically requiresignificant heat sinks to dissipate the waste heat, although therelatively smooth output drive voltages are best for motor drive and lowRFI EMC issues. Furthermore, AC motor applications typically use triacsor SCRs (silicon controlled rectifiers) for phase switching control ofmotor power.

[0106] Generic Obstacle Detection

[0107] To detect an obstruction when the sunroof panel is closing in itsautomatic operation mode, in brief, the microprocessor measures themotor current and speed for the ongoing actuation and compares againstan empirically-determined algorithm within the controller for motorcurrent and speed versus position and/or time. When calculations basedupon sensed current, pulse period, derivatives thereof, and actuatorposition cause a calculated threshold to be exceeded, an obstruction isascertained and the sunroof is brought back to its full OPEN or fullVENT position.

[0108] A trippoint calculation utilizes memory buffers to store motoroperation parameter information needed to make a determination aboutobstruction detection. If the sunroof is calibrated and is subsequentlyplaced in the automatic close mode, the controller 2 uses the contentsof these buffers to determine the presence of an obstruction. Variationsof numerical term and factor values of the obstacle detection thresholdalgorithm of cited references, commonly owned, are fully anticipated perempirical characterization of any particular actuation system. Such termand factor values can be predetermined and/or adaptive via DSPalgorithms. It is impractical to even attempt to show all apparentvariations.

[0109] Trip point algorithms are based upon empirically obtainedmeasurements from actuations over chosen ranges of operating conditions.

[0110] The pulse period relates to sunroof speed. As the speedincreases, factors that utilize pulse period (PP) cause obstructionindication more easily than at low speed. Stated another way, thethreshold is made to be close to the operating current since there is ashorter time to react to the occurrence of an obstruction.

[0111] Other terms relate to motor current. Another term avoidsobstruction sensing for a sharp current increase due to spurious andshort lived currents that might otherwise cause false obstructiondetection. Nominal values for I (motor current) are from 40 to 80. Thesedo not correspond to units of amperes or milliamperes, but are insteadscaled engineering units based upon the motor and circuitry used tosense the motor current.

[0112] Startup Obstruction Detection Summary

[0113]FIG. 4 shows typical startup energization characteristics ofcurrent and per speed for a motor. Startup obstacle detection issomewhat difficult because the characteristic startup current for amotor typically begins with a quick inductive rise toward a peak valueprimarily limited by the resistive impedance of the motor coil and speedstarts from zero. Startup current peaks typically approach stalled rotorcurrent of approximately four and one half to six times normal operatingcurrent. Starting currents peak quickly, approaching a typical maximumvalue of approximately 75% of stalled rotor condition, after which motorcurrent gradually reduces to a steady state operating conditionprimarily due to increasing back EMF (electromotive force) generated bygradual increasing rotation speed of the rotor. Higher reference valuesfor current sense scaling can be preferred for startup and stallconditions versus normal steady operation.

[0114] Relatively fast clock speeds of microcontroller circuitry enablefast detection of hard obstacles at startup by monitoring parameters ofmotor current and motor PP. Algorithms based upon monitored parametervalues of motor voltage and motor current load, during a fixed startuptime interval enable predicted anticipation of motor speed. If thesensed speed at the end of the fixed startup time interval is below adetermined threshold, then an obstacle is determined. If the sensedcurrent at the end of the fixed startup time interval is above adetermined threshold, then an obstacle is determined.

[0115] Expressed in other terminology, after allowing some small initialamount of time for the motor rotor to begin rotation, I is immediatelymeasured and compared against a fixed maximum threshold value and PP isimmediately measured and compared against some maximum threshold numberof clock cycles. If either measured parameter variable exceeds its fixedthreshold value, then a hard obstacle detection is made and motor driveis immediately discontinued, and the actuation is briefly reversed torelease the obstruction. The initial amount of time is that time duringwhich a significant increase in motor speed is expected to bemeasurable. A larger motor and a motor with greater associatedrotational inertia from the load will both typically require a longeracceleration time.

[0116] Hard Obstacle Detection Summary

[0117] In brief, hard obstacle detection is generally based uponadaptive algorithms that evaluate an immediate short history of motorcurrent and speed of the immediate actuation. Hard obstacle detection isvia fast processing algorithms of at least one FIFO memory containingsequential measurements of motor electrical current and per speed.Running calculations based upon the FIFO memory of measured values arestored in at least one FIFO memory. Hard obstacle detection afterstartup is performed via two algorithms. One algorithm method is basedupon speed and rates of change of speed (also known as acceleration anddeceleration) and/or rates of change of acceleration or deceleration(also known as jerk) to determine at least one value in excess of atleast one limit. Another algorithm method is based upon measurements ofmotor current and derivatives thereof based upon time and/or position attimes and/or positions determined at each motor commutation pulse andwith further calculations based thereupon to determine at least onevalue in excess of at least one limit.

[0118] Hard obstacle threshold detection limits based upon motor currentare also modified based upon the number of microcontroller pulsescounted per motor current commutation pulse period. The condition ofexceeding either one of these adaptive threshold limits is construed ashard obstacle detection. Implementation of this method is by utilizationof at least one FIFO memory for storing such running measured values asPP and/or I, as previously defined. Additional FIFO memory can be usedto store additional running calculated values based on PP and/or I.These running calculated values based upon time and/or position are oftypes including first derivative, second derivative, higher orderderivative(s), weighted running averages, algebraic expressions,logarithms, statistical functions, and the like for computation ofadaptive thresholds based thereupon.

[0119] Fast real time digital processing routines are simplifiedalgebraic equations derived from piecewise linearization and/or othersimplified algorithms for curve fitting of empirical sunroof paneloperational data. Depending on accuracy requirements and relativealgorithm processing speeds, higher order curve-fitting routines areanticipated. Hard obstacle detection occurs when either I and/or PPexceed a running adaptive threshold value comprised of terms based uponfixed, static, and/or dynamic values.

[0120] Soft Obstacle Detection Summary

[0121] In brief, soft obstacle detection is generally based uponadaptive algorithms that evaluate an immediate history of motor currentand speed of the immediate actuation. The immediate history is muchlonger than that immediate short history per hard obstacle detectionalgorithms. Soft obstacle detection is also via fast processingalgorithms of at least one FIFO memory containing sequentialmeasurements of motor electrical current and per speed. Runningcalculations based upon the FIFO memory of measured values are stored inat least one FIFO memory. Soft obstacle detection after startup isperformed via two algorithms. One algorithm method is based upon speedand rates of change of speed (deceleration) to determine at least onevalue in excess of at least one limit. Another algorithm method is basedupon measurements of motor current and derivatives thereof based upontime and/or position at times and/or positions determined at each motorcommutation pulse and with further calculations based thereupon todetermine at least one value in excess of at least one limit.

[0122] Implementation of this unique method is by utilization of atleast one FIFO memory for storing such running measured values as PPand/or I. Additional FIFO memory can be used to store additional runningcalculated values based on PP and/or I. These running calculated valuesbased upon time and/or position are of types including first derivative,second derivative, higher order derivative(s), weighted runningaverages, algebraic expressions, logarithms, statistical functions, andthe like for computation of adaptive thresholds based thereupon. Fastreal time digital processing routines are simplified algebraic equationsderived from piecewise linearization and/or other simplified algorithmsfor curve fitting of empirical sunroof panel operational data. Dependingon accuracy requirements and relative algorithm processing speeds,higher order curve-fitting routines are anticipated. Soft obstacledetection occurs when either I and/or PP exceed a running adaptivethreshold value comprised of terms based upon fixed, static, and/ordynamic values.

[0123] Software Digital Signal Processing Techniques

[0124] Algorithm methods generally used for data analysis can includetime domain and/or frequency domain techniques. These data processingtechniques include, but are not restricted to, algebraic manipulation,logical comparison, convolution, convolution integral, Fouriertransforms, fast Fourier transforms, discrete Fourier transforms,z-transforms, wavelet analysis, and the like. Digital signal processingtechniques and algorithms are used to monitor data from motor operationparameters and/or derived data thereof in practical real time toascertain motor operation parameter changes characteristic of undesiredobstacle loading.

[0125] Collision Detection Notation

[0126] Measured readings of hardware-filtered I_(n) (motor current) andPP_(n) (pulse period) are triggered by and thus synchronized with motorcurrent commutation pulse detections. Multiple FIFOs (first-in-first-outmemories) are utilized to store running measurements of I_(n) and PP_(n)as well as calculated values derived therefrom. In a very general sense,both hard obstruction detection and soft obstruction detectionalgorithms are based upon weighted factors of the history of runningmeasurements and running calculations. Hard obstacle detection is biasedmore toward a relatively recent-term history, whereas soft obstacledetection is weighted more toward a relatively longer-term history.

[0127] Generalized obstacle detection is considered as an abbreviatedsubset from a very broad set of weighted factors based upon a runninghistory of measured motor operation parameters and data calculationsbased thereupon for the immediate actuation operation. Prior methods ofobstacle detection implement the method of predetermining an operationparameter template based upon some number of running weighted averagesof sequential prior actuations. The present method uses no suchpredetermined operation parameter template, but rather calculates bothhard and soft obstacle detection thresholds during the immediateactuator operation based upon at least one software algorithm.

[0128] Motor speed fractionally varies significantly more than doesmotor current with magnitude of motor supply voltage. Motor torque loadcorrelates very well with motor current. Thus, motor current is theprimary measured parameter of immediate importance for both hard andsoft obstacle detection. Obstacle detection is desensitized toelectronic noise by implementing a running software filter to calculatenoise-reduced motor current for determination of obstacle detection.Obstacle detection is based upon measurements of motor current and motorspeed per the following notations.

[0129] Processing equations, data, and variables utilize the followingnotations and definitions.

[0130] Subscript n represents pulse number, n≧0, where

[0131] n=0≡most recent motor current commutation pulse

[0132] n=1≡motor current commutation pulse just prior to n=0

[0133] n=2≡motor current commutation pulse just prior to n=1.

[0134] Subscript m represents the identifier for motor operation termweighting factors, m≧0, where

[0135] Km≡empirically determined term-weighting factors, alternativelyadaptive.

[0136] Measured motor operation parameters, FIFO registers, where

[0137] I_(n)≡measured motor current at the n^(th) commutation pulse

[0138] PPn≡counted number of clock cycles per pulse period between motorcurrent commutation pulses from pulse n to (n+1).

[0139] Calculated motor operation values, FIFO registers, where

[0140] I_(R0) ≡calculated running software-filtered value of priorsequential measured motor currents in range zero

[0141] I_(R1) ≡calculated running software-filtered value of priorsequential measured motor currents in range one

[0142] I_(Ra-f)≡calculated running software-filtered value of priorsequential measured motor currents in ranges a-f (a through f) . . .

[0143] {Min I_(Ra-r)}≡determined value of a minimum of motor currentreadings in prior sequential ranges a-f

[0144] {Max I_(Ra-f)}≡determined value of a maximum of motor currentreadings in prior sequential ranges a-f

[0145] PP_(R0)≡calculated running software-filtered value of priorsequential counted PP in range zero

[0146] PP_(R1)≡calculated running software-filtered value of priorsequential counted PP in range one

[0147] PP_(Ra-f)≡calculated running software-filtered value of priorsequential counted PP in ranges a-f

[0148] Very recent motor operation parameter history is represented byat least one data set range given numeric identifier. Range zeroincludes data sets represented by the most recent sequential few motorcurrent commutation pulses, typically 4 to 8 pulses. Range one includesdata sets represented by a similar number of 4 to 8 motor currentcommutation pulses immediately prior to range zero. Although ranges zeroand one typically represent data sets for 4 to 8 motor currentcommutation pulses each, the quantity of represented data sets can be aslow as 1 and higher than 16, as determined by system operationrequirements and monitored dynamic system conditions. Furthermore, thequantity of represented pulses per data set can be interactivelymodified in response to variations of measured motor operationparameters. The number of data sets in ranges one and two areempirically determined somewhat by the extent of software filteringnecessary to adequately represent very recent history of motor operationparameters.

[0149] The quantity of such numeric identifier data ranges can be as lowas 1 and higher than 8, depending upon actuator system dynamic responseand fast filtration algorithm requirements. Furthermore, the quantity ofdata sets can be interactively modified in response to variations ofmeasured motor operation parameters. Fast filtration requirements aredetermined by the electrical noise level, the number of motor currentcommutation pulses per motor revolution, the numbers of gear teeth indrive mechanisms, mechanical vibrations, and the like.

[0150] Longer recent motor operation parameter history is represented byat least one range given alphabetic identity. Range a, b, c, d, e, and fincludes six data sets each represented by a significantly larger dataset range than numeric identifier ranges zero and one. Although sixranges are here described, this quantity can be as low as one and higherthan six, as determined by system operation requirements and monitoreddynamic system conditions. Typically, each of the ranges a-f includes 8to 24 data sets. Range a represents the most recent sequential motorcurrent commutation pulses. Range b represents the similar-sized rangeimmediately preceding range a. Likewise, up to range f. The number ofdata sets in ranges a-f can be as low as one and significantly higherthan 24, depending upon slow filtration algorithm requirements.Furthermore, the number of data sets in each of ranges a-f, as well asthe quantity of ranges, can be interactively modified in response tovariations of measured motor operation parameters. Fast filtrationrequirements are determined by the electrical noise level, the number ofmotor current commutation pulses per motor revolution, the numbers ofgear teeth in drive mechanisms, mechanical vibrations, frequency ofperiodic load disturbances, and the like.

[0151] Following examples will describe the use of two numericidentifier data set ranges zero and one, for very recent motor operationdata, with each range representing data sets for six motor currentcommutation pulses. Following examples will also describe the use of sixalphabetic identifier data set ranges a-f, for longer recent motoroperation data, with each range representing data sets for 15 motorcurrent commutation pulses.

[0152] In a simple preferred case, calculated running software-filteredalgorithms determine even-weighted boxcar averages of sequential datafrom defined FIFO ranges, as follows.

[0153] For defined range zero,

n=x−1

I_(R0)≡A_(n)I_(n)

n=0

[0154] and

n=x−1

PP_(R0)≡A_(n)PP_(n).

n=0

[0155] In this simple preferred example case, set

x=6 and A_(n)=(1/x)

[0156] to produce evenly weighted boxcar averages from data representingsix sequential motor current commutation pulse measurements. Andlikewise,

n=2x−1

I_(R1)≡A_(n)I_(n)

n=x

[0157] and

n=2x−1

PP_(R1)≡A_(n)PP_(n)

n=x

[0158] for range one.

[0159] In similar manner, evenly weighted boxcar averages are calculatedfrom data in defined alphabetic ranges, as follows. By setting

y=15 and A_(n)=(1/y)

[0160] and applying into equations

n=y−1

I_(Ra)≡A_(n)I_(n)

n=0

n=2y−1

I_(Rb≡A) _(n)I_(n)

n=y

n=3y−1

I_(Rc)≡A_(n)I_(n)

n=2y

n=4y−1

I_(Rd)≡A_(n)I_(n)

n=3y

n=5y−1

I_(Re)≡A_(n)I_(n)

n=4y

n=6y−1

I_(Rf)≡A_(n)I_(n)

n=5y

[0161] and into equations

n=y−1

PP_(Ra)≡A_(n)PP_(n)

n=0

n=2y−1

PP_(Rb)≡A_(n)PP_(n)

n=y

n=3y−1

PP_(Rc)≡A_(n)PP_(n)

n=2y

n=4y−1

PP_(Rd)≡A_(n)PP_(n)

n=3y

n=5y−1

PP_(Re)≡A_(n)PP_(n)

n=4y

n=6y−1

PP_(Rf)≡A_(n)PP_(n)

n=5y

[0162] These evenly weighted running software filtered averages are usedto reveal calculated trends in larger recent motor operating parameterhistory.

[0163] For a system where algorithm processing must be very fast, theuse of range sizes that are integer powers of the number 2, e.g. 1, 2,4, 8, 16, 32, etc., result in boxcar averaging weighting factors thatare very quickly multiplied by simply and quickly bit or nibble shiftingthe measured data.

[0164] In addition to running filtered shorter-term and longer-termaverages of respective numeric range data and alphabetic range data itis necessary to compute dynamic noise levels of measured parameters tocompensate obstacle detection thresholds for system noise. Increasedrelative noise levels necessitate increased obstacle detectionthresholds to avoid false obstacle detection with subsequent stoppingand reversal of the actuator. Such noise levels are computed fromminimums and maximums determined by the following definitions.

[0165] {MinI_(Ra)}≡minimum value of motor current readings in range a

[0166] {MinI_(Rb)}≡minimum value of motor current readings in range b

[0167] {MinI_(Rc)}≡minimum value of motor current readings in range c

[0168] {MinI_(Rd)}≡minimum value of motor current readings in range d

[0169] {MinI_(Re)}≡minimum value of motor current readings in range e

[0170] {MinI_(Rf)}≡minimum value of motor current readings in range f

[0171] {MaxI_(Ra)}≡maximum value of motor current readings in range a

[0172] {MaxI_(Rb)}≡maximum value of motor current readings in range b

[0173] {MaxI_(Rc)}≡maximum value of motor current readings in range c

[0174] {MaxI_(Rd)}≡maximum value of motor current readings in range d

[0175] {MaxI_(Re)}≡maximum value of motor current readings in range e

[0176] {MaxI_(Rf)}≡maximum value of motor current readings in range f

[0177] Maximums and minimums from multiple alphabetic ranges are perthese examples.

[0178] {MinI_(Rb-f)}≡minimum value of motor current readings in rangesb-f

[0179] {MaxI_(Rb-f)}≡maximum value of motor current readings in rangesb-f

[0180] Obstacle detection is based upon the history of minimum andmaximum motor operation parameter measurements. The difference betweenthe minimum and the maximum values gives an indication of the measurednoise levels.

[0181] A very generic equation for obstacle detection includes abovefactors, shown below. Note that the term including the factor I_(R0) isincorporated into the term on the left side and accommodated by suitableadjustment of remaining K_(n) factors.

[0182] Hard and/or Soft Obstruction Detection:

[0183] If I_(R0)≧[K₁ I_(Ra)]+[K₂ I_(Rb)]+[K₃ I_(Rc)]+[K₄ I_(Rd)]+[K₅I_(Re)]+[K₆ I_(Rf)]+[K₇ PP_(Ra)]+[K₈ PP_(Rb)]+[K₉ PP_(Rc)]+[K₁₀PP_(Rd)]+[K₁₁ PP_(Re)]+[K₁₂ PP_(Rf)]+[K₁₃ I_(R1)]+[K₁₄{MinI_(Ra-f)}]+[K₁₅ {MaxI_(Ra-f)}]+[K₁₆ PP_(R0)]+[K₁₇ PP_(R1)]+K₈

[0184] THEN AN OBSTACLE IS DETECTED

[0185] All of the above factors based upon I, PP, and calculated valuesthereof are preferred to be simple evenly weighted running averagesand/or simple maximum and minimum comparisons that process relativelyquickly. The large quantity of algebraic and logical operationsprecludes complete processing fast enough to quickly detect anobstruction and stop before pinch forces exceed safe limits.

[0186] Algorithm processing for hard and soft obstruction detection isdivided into two separate equations, weighting the various termsdepending upon magnitude of importance and processing time requirements.The following examples show generalized and preferred algorithms forhard and soft obstruction detection. K_(n) factors are empiricallydetermined to meet system dynamic performance mandates.

[0187] Hard Obstruction Detection:

[0188] IF I_(R0)≧[K₁ I_(R1)]+[K₂ PP_(R1)]+K₃

[0189] THEN AN OBSTACLE IS DETERMINED.

[0190] Hard obstruction detection is imperative to determine veryquickly so this implementation keeps processing requirements to a lowlevel, yet enables fast and reasonably precise hard obstacle detection.Large range average terms including current, pulse period, minimumcurrent, and maximum current are all considered insignificant enough inthe tradeoff against speed so they are removed. Small range averagemotor current, I_(R0), is thus unitlessly compared with the sum of threeterms I_(R1), PP_(R1), and K₃. This essentially compares immediateaverage current with immediately prior average current and immediatelyprior average pulse period plus an offset constant. Thus, a quickincrease in sustained motor current tends toward hard obstructiondetermination. High values of pulse period indicate that the motor isrunning slow with high torque, so the difference between the actuatorforce and the maximum allowable pinch force is also low. Thus, highvalues of pulse period also tend toward hard obstruction determination.

[0191] Soft Obstruction Detection

[0192] IF I_(R0)≧[K₄ PP_(Rb-f)]+[K₅{Min I_(Rb-f)}]+[K₆{Max I_(Rb-f)}]+K₇THEN AN OBSTACLE IS DETERMINED.

[0193] Soft obstruction detection is not nearly as time sensitive, as ishard obstruction detection, thus additional terms can be computed in thetime allowed before the slow increase in entrapment force exceedsmaximum allowable values. The large range average term for pulse periodof ranges b-f provides a relatively stable representation of pulseperiod that relates inversely with speed. As speed is decreased, pulseperiod is increased. High values of PP indicate that the motor isrunning slow with high torque, so the difference between the actuatorforce and the maximum allowable pinch force is also low. Thus, highvalues of pulse period also tend toward hard obstruction determination.The large range minimum and maximum terms for motor current in rangesb-f are lumped together into two terms to provide a practicalcombination of terms representing both average current and current noiserange. Dynamic loading conditions produce dynamic currents that resultin a wider range of maximum, minimum, and maximum minus minimum currentvalues. High values of current noise necessitate higher soft obstructiondetection threshold values to avoid nuisance detection.

[0194] Depending upon the periodicity of motor loading conditions, it ispossible to not only adapt thresholds reactively, but also topredictively adapt thresholds in anticipation of continued cyclicloading conditions. Software algorithms that evaluate various alphabeticrange sizes of the FIFO data set to quantify max and min enabledetermination of alternating amplitudes characteristic of frequencyand/or frequencies for which motor operation parameter loading revealscyclic periodicity. Adaptive predictive compensation of soft obstacledetection enables improved sensitivity for set detection thresholds withreduced affect by cyclic dynamic loads such as wind buffeting orrepetitive gear loading. The obstacle detection threshold is cyclicallymodified in anticipation of the regular disturbance detected. Suchcyclic obstacle detection modification can occur simultaneously withdynamic transient response of obstacle detection threshold levels, asotherwise described.

[0195] Alternative Incremental Encoding Implementions

[0196] Sensorless electronic sensing of motor current commutation pulsesis the preferred low cost method of motor rotor movement disclosedherein in fair detail. In certain circumstances, it may be preferable touse alternative absolute and/or incremental position sensing by at leastone hardware sensor means. Such circumstances that might lead to thechoice to implement position sensing via hardware sensors include:1)desire to sense a greater number of encoder pulses per motor rotorrevolution than produced by motor commutation segments to enable fasterobstacle detection per time and/or per rotation; 2)high electrical noiseenvironment that makes it difficult to maintain high accuracy ofposition count from electronic sensing of encoder pulses; 3)actuatormechanisms that potentially allow mechanical windup and/or jitter thatmechanically feeds back to the motor rotor allowing production of rotorelectronic pulses representing ostensible actuator motion and/or motionin the incorrect sense; and 4)systems for which it is desired tomaintain strict position accuracy regardless of electrical noise andmechanical disturbances.

[0197] One particular general alternative preferred embodiment forincremental positioning sensing utilizes two sensing elements physicallyaligned to produce phase quadrature signals from a relatively movingtarget. Two sensing elements in phase quadrature orientation provideinformation about both speed and direction. A typical example of thisimplementation is to attach a diametrically magnetized (two pole) magnetto the rotor of a motor with two symmetrical bipolar latch Hall effectsensors held in 90 mechanical degrees and in proximity to sense themagnet. By this setup, there are two transitions per Hall effect sensorper pole pair, thus a total of four transitions per motor rotorrevolution by which to trigger measurements of motor operationparameters as herein described with motor current commutation pulsesensing. Alternatively, use of a ring magnet having 10 pole pairs withsimilar symmetric bipolar latch Hall effect sensors in phase quadraturewill produce 40 transitions per motor rotor revolution.

[0198] Various sensing properties utilized for incremental and/orabsolute position sensing including optical, magnetic field, electricfield, potentiometric, and the like. Magnetic fields are sensed by Halleffect, magnetoresistance, anisotropic magnetoresistance, giantmagnetoresistance, collosal magnetoresistance, Wiegand effect, fluxgatemagnetometry, magnetodiode, magnetotransistor, superconducting quantuminterference magnetometry, and more. Electric fields are sensed byelectrodes of fixed and/or variable geometry with sensitive electroniccircuitry. Optical fields are sensed by photodiode, phototransistor,photoresistor, and thermocouple (for slowly changing fields converted toheat). Electromagnetic fields are sensed by electrodes as coupledantennas with tuned electronic circuitry.

[0199] Battery and Motor Protection

[0200] Battery voltage is monitored to determine when the power supplydrops below some minimum value so the motor drive can be discontinued.This protects against battery rundown in the situation where a lowvoltage battery power supply is insufficient to drive the motor and/orsustained electrical load might pose a risk of draining the battery. Atimeout timer to limit motor drive time is an additional preferred meansby which similar protection is affected. Motor protection is optionallyprovided by such means as a current limiting diode, a positivetemperature coefficient resistor, and/or a thermal cutout switch.

[0201] Ice Breaking

[0202] An alternative functional capability is an ice-breaking modewhereby full motor force is allowed for more than the minimum amount oftime and/or distance to enable a window and/or sunroof panel to breakloose from ice. This feature will be appreciated by many in coldclimates who find their car windows and/or sunroofs stuck in positiondue to ice. For visibility and/or escape safety, this option is fullyanticipated as a preferred functional feature. For this optional mode ofoperation, the controller remembers the starting position for safetyreference and will not allow significant deviation therefrom if hardobstacle detection conditions are sustained. Under manual switched inputcontrol, the controller allows for alternating direction application offull motor force for some predetermined maximum distance and/or time,for example three millimeters and/or three seconds alternately in eitherdirection before enabling hard obstacle detection capability. Thecharacteristic current peak and then drop usually occurs overapproximately 10 motor current commutation pulses, which corresponds toapproximately 3 mm. IF startup current deviates significantly abovenormal AND IF the number of motor current commutation pulses deviatessignificantly below 10 during the usual amount of time for a typicalstartup characteristic, THEN the stall timeout timer can be increased upto perhaps 5 seconds to break ice by a simple algorithm based upon thetwo deviations. Thereafter, if normal actuator motion does not commenceby breaking loose from the ice, the actuator can then be retracted toremove hard obstacle preload and the ice breaking cycle repeated. 3 mmis typically sufficient to break ice and also corresponds with thestartup hard obstacle detection distance under conditions of obstaclepreload. If the motor current remains high and the number of pulses isnormal at the characteristic startup time, then a hard obstacle isdetermined. For safety considerations, this feature might be enabledonly when the sensed ambient temperature is sufficiently cool to allowfor the existence of ice conditions. Soft frozen ice might actually takea longer amount of time and/or distance to break free than hard frozenice, there necessitating adjustment of the maximum set times and/ordistances based on sensed temperature. An alternate method of breakingice can be enabled with a switch press sequence. For example, two tapsand hold, then the unit can go into manual mode which disablesobstruction detection.

[0203] Timed Power Latch

[0204] An optional feature included in the preferred embodiment is forthe controller to self latch power for an amount of time after thevehicle ignition is switched off, for example 15 seconds, to allow thevehicle operator to close the sunroof and/or windows. Likewise, anothervehicle security alternative is to allow the operator to select theoption for the vehicle sunroof and/or windows to automatically closewhen the ignition is switched OFF. This feature can work in conjunctionwith an alternative feature whereby the vehicle cabin temperature issensed for the automatic function of opening the sunroof and/or thewindows to the VENT position when the sensed vehicle cabin temperatureexceeds some maximum set temperature. Similarly, a sunroof and/or windowcan automatically close to the fully closed position when the sensedvehicle cabin temperature is below some set temperature. A reasonablehysteresis between the vent set temperature and the cool closetemperature will reduce unnecessary cycling between VENT and CLOSEDpositions.

[0205] Vehicle Communication Systems

[0206] Communication motor vehicle computer via the vehiclecommunication bus problem is optional based upon interface systemcapability and application requirements. Examples of vehiclecommunication buses include SAE (Society of Automotive Engineers) J1850,CAN (Controller Area Network), and numerous others developed by variousautomotive manufacturers. Such communication means can communicateactuator system fault conditions including faulty motor coil orcommutator segment, low actuation speed, excessive motor current, drivemechanism range limitation, component failures, system failures, and thelike.

[0207] This vehicle speed information might be obtained by vehicle busmultiplexing (MUX) communication and/or demultiplexing (DEMUX)communication from such sources as speedometer, transmission, andtransfer case as is used by other sources such as cruise control system,anti-skid braking system, and traction control system. Similarly,information from the vehicle environmental control systems might provideinformation such as fan speeds and ventilation settings that can be ofvalue to anticipate an amount of static and transient loading on thesunroof and windows. Utilization of a relatively fast respondingpressure sensor enables empirically-correlative predictive modificationof obstacle detection thresholds to overcome variable changes ofactuator load due to static, periodic dynamic, and transient dynamicvehicle cabin atmospheric pressures. An optional anticipated feature isfor the vehicle sunroof position to be automatically moved to a positionto reduce sensed cabin wind buffeting and/or noise.

[0208] Empirical Actuation Motor Load Profile Equation and Algorithm

[0209] Nominal operation parameters for obstacle detection threshold areempirically characterized as motor current loading versus actuatorposition. Alternative empirical characterizations include motor currentversus time, motor speed versus time, motor speed versus position, andcombinations thereof as per prior art references. In the presentembodiment, this algebraic representation has a general simplifiedalgebraic form for fast computation via DSP processing, particularlyimplementing adding and/or bit shifting and/or byte shifting operations.These types of empirical data manipulations for conversion to fastcomputing real time microcontroller algorithms have been found to beapplicable to various diverse combinations of vehicles and sunroofs.

[0210] To accommodate each vehicle's fixed aerodynamic profile, it istypically necessary to empirically determine and characterize each typeof vehicle with each type of sunroof for each direction of openingand/or closing over a wide range of vehicle speed and temperatureconditions to determine all appropriate adaptive obstacle detectionthreshold calculation algorithms.

[0211] The present invention provides a system wherein empirical datarepresenting a range of operational conditions and empiricallydetermined functional terms and factors for an automatic poweredactuator can be converted by simplified piecewise line and/or curvefitting means to algorithmic equations with coefficients that supportfast real time processing such that adaptive sensing thresholds areenabled resulting in improved sensitivity, improved accuracy, andimproved time response to obstruction conditions. Based upon thecomplexity of the actuation system, sensitivity requirements, and timeresponse requirements, additional refinements as threshold errorreducing terms can be characterized for inclusion into the sensingthreshold equation using similar methods.

[0212] Utilization of simplified equations in the processing algorithmsallows for fast performance in real time without relying upon previousmethods such as using fixed characteristic signature templates and/orslowing down actuator motor drive speed.

[0213] Alternative Applications

[0214] When used to operate a power sunroof the control circuit can openthe sunroof, close the sunroof, and tilt open the sunroof to a ventposition. The preferred embodiment of the invention automaticallycontrols a power sunroof but similar actuation of other automaticpowered panels or windows is anticipated using the disclosed controlcircuit and obstruction detection methods.

[0215] Load sensing threshold determinations via similar methods to thisteaching are anticipated for alternative application functions includingthose without human involvement and for applications without potentialfor equipment damage. It is fully anticipated and expected that systemsand methods can well be similarly utilized to control practically anysystem variable by monitoring at least one operational parameter suchthat the controlled variable is not required to be safety related. Thismethod and system, based on empirical determinations of operatingparameters, running measurements of operating parameters, FIFO memoriesfor storing measured and/or calculated values, fast computationalgorithms, and subjective determination of load threshold parametervalues can generally be applied to systems and devices where suchvariable thresholds are chosen for functional means other than forpurposes of human safety or equipment protection. The large scopeincludes systems having more than one such controlled variable.

[0216] Aeronautical systems have applicability of the inventivedisclosure. An example is the detection of the onset of stall conditionsby the change in force and/or a cyclical varying lift produced by anairfoil as it is increasingly approaching a stall condition. Suchimpending stall condition is the sensed input, instead of obstacledetection, that precedes the control response to outputs includingengine power, flap actuation, elevator actuation, aileron actuation,rudder actuation, ice boot actuation, and the like. Analogously,hydraulic liquid flow control systems for ships and submarines areanticipated.

[0217] Hydraulic, pneumatic, and mechanical systems are similarlyanticipated by computations based upon time, position, and/or otherderivatives of monitored parameters including: position, pressure,volume, flow, force, torque and the like. Utilization of analogousalgorithms and adaptive methods and systems enables obstacle detection,and/or arbitrary functional limit detections.

[0218] Broad Encompassed Alternatives

[0219] While the present invention has been described with a degree ofparticularity, it is the full intent that the invention includemodifications and altercations from the disclosed and anticipateddesigns falling within the spirit and/or scope of the appended claims.

1. Apparatus for controlling motion of a motor driven element in avehicle over a range of motion and for altering said motion whenundesirable resistance to said motion is encountered, said apparatuscomprising: a) a sensor for measuring a parameter of a motor coupled tothe motor driven element that varies in response to a resistance tomotion during all or part of a range of motion of the motor drivenelement; b) a memory for storing a number of measurement values from thesensor based on measurements of said parameter over at least a portionof said range of motion; c) a controller coupled to the memory fordetermining to de-activate the motor based on the measurement valuesstored in the memory as the motor driven element moves over its range ofmotion; and d) a controller interface coupled to the motor for alteringmotion of said motor driven element in response to a determination madeby the controller.
 2. A method for controlling motion of a motor drivenelement in a vehicle over a range of motion and for altering said motionwhen undesirable resistance to said motion is encountered, said methodcomprising: a) measuring a parameter of a motor coupled to the motordriven element that varies in response to a resistance to motion duringall or part of a range of motion of the motor driven element by taking amultiplicity of measurements as the motor moves the motor driven elementover its range of motion; b) storing a number of measurement valuesbased on measurements of said parameter over at least a portion of saidrange of motion; c) determining that the parameter is outside aparameter range based on previous stored measurement values as the motordriven element moves over its range of motion; and d) altering motion ofsaid motor driven element in response to a determination that theparameter is outside the parameter range.
 3. The method of claim 2wherein the motor driven element is a window or panel and additionallycomprising reverse actuating the window or panel prior to moving saidwindow or panel in a direction to close the window or panel.
 4. Themethod of claim 3 additionally comprising maintaining a position of thewindow or panel based on the sensed parameter and the reverse actuationis initiated if a leading edge of the window or panel is near a closedposition.
 5. The method of claim 4 movement is first initiated toward aclosed position when a leading edge of the window or panel is near theclosed position and wherein the reverse actuation is performed upon asensing of an obstacle that is based on determining the parameter isoutside the parameter range.
 6. Apparatus for controlling activation ofa motor coupled to a motor vehicle window or panel for moving saidwindow or panel along a travel path and deactivating the motor if anobstacle is encountered by the window or panel, said apparatuscomprising: a) a sensor for sensing movement of the window or panel andproviding a sensor output signal related to a speed of movement of thewindow or panel; b) a switch for controllably actuating the motor byproviding an energization signal; and c) a controller having aninterface coupled to the sensor and the switch for controllablyenergizing the motor; said controller sensing a collision with anobstruction when power is applied to the controller by: i) monitoringmovement of the window or panel by monitoring a signal from the sensorrelated to the movement of the window or panel; ii) identifying acollision of the window or panel with an obstacle due to a change in thesignal from the sensor that is related to a change in movement of thewindow or panel; and iii) outputting a control signal to said switch todeactivate said motor in response to a sensing of a collision between anobstacle and said window or panel.
 7. The apparatus of claim 6 whereinthe controller comprises a programmable controller including aprocessing unit for executing a control program and including a memoryfor storing multiple window or panel speed values corresponding to asignal received from the sensor.
 8. The apparatus of claim 6additionally comprising one or more limit switches for use by thecontroller to determine window or panel position for use in identifyinga collision.
 9. The apparatus of claim 6 wherein the control programadjusts an obstacle detection threshold in real time based on immediatepast measures of the signal sensed by the sensor to adapt to varyingconditions encountered during operation of the window or panel.
 10. Theapparatus of claim 6 wherein the controller maintains a position of aleading edge of the window or panel and further wherein the controllerreverse energizes the motor to move the window or panel away from aclosure position prior to activating the motor to close the window orpanel.
 11. The apparatus of claim 10 wherein the controller reverseenergizes the motor in response to a sensing of an obstacle and thereverse energizing and attempt to move the window or panel to a closedposition is performed to confirm sensing of the obstacle.
 12. Apparatusfor controlling activation of a motor for moving an object along atravel path and de-activating the motor if an obstacle is encountered bythe object comprising: a) a movement sensor for monitoring movement ofthe object as the motor moves said object along a travel path; b) aswitch for controlling energization of the motor with an energizationsignal; and c) a controller including an interface coupled to the switchmeans for controllably energizing the motor and said interfaceadditionally coupling the controller to the movement sensor formonitoring signals from said movement sensor; said controller comprisinga stored program that: i) determines motor speed from an output signalfrom the movement sensor; ii) calculates an obstacle detect thresholdbased on motor speed of movement detected during at least one priorperiod of motor operation; iii) compares a value based on currentlysensed motor movement with the obstacle detect threshold; and iv)outputs a signal from the interface to said switch for stopping themotor if the comparison based on currently sensed motor movementindicates the object has contacted an obstacle. 13 The apparatus ofclaim 12 wherein the controller includes a buffer memory for storingsuccessive values of motor movement for use in determining the obstacledetect threshold.
 14. The apparatus of claim 12 wherein the controllerincludes a clock and an input from the movement sensor is in a form of asequence of pulses and further wherein the controller counts clocksignals occurrences between receipt of pulses to provide an indicationof motor speed.
 15. The apparatus of claim 12 wherein the controllerincludes an interface for monitoring user actuation of control inputsfor controlling movement of the window or panel and wherein thecontroller maintains a motor energization sequence a specified minimumtime period in response to a short period user actuation of said controlinputs to maintain position accuracy in monitoring window or panelmovement.
 16. The apparatus of claim 12 wherein the controller includesan interface for monitoring user actuation of control inputs forcontrolling movement of the object and wherein in response to aspecified input the controller conducts a calibration motor energizationsequence to determine parameters of object.
 17. The apparatus of claim12 wherein the motor is coupled to a motor vehicle window or panel andwherein the controller includes an interface for monitoring useractuation of control inputs for controlling movement of the window orpanel and wherein the controller maintains a position indication whichis updated in response movement of the window or panel and furtherwherein the controller reverse actuations the motor near an end point inan object path of travel to avoid false obstacle detection in the regionof closure of the window or panel.
 18. The apparatus of claim 12 whereinthe sensor is a current sensor and wherein the controller includes meansfor adjusting the obstacle threshold based on dynamic motor current assensed from the current sensor to take into account varying loadsexperienced by the motor.
 19. Apparatus for controlling activation of amotor for moving a window or panel along a travel path and de-activatingthe motor if an obstacle is encountered by the window or panelcomprising: a) a sensor for sensing movement of a window or panel alonga travel path; b) a switch for controlling energization of the motorwith an energization signal; and c) a controller coupled to the switchfor controllably energizing the motor and having an interface couplingthe controller to the sensor and to the switch; said controllercomprising decision making logic for: i) monitoring a signal from thesensor; ii) calculating an obstacle detect threshold based on the signalthat is detected during at least one prior period of motor operation, ora predetermined threshold; iii) comparing a value based on a currentlysensed motor parameter with the obstacle detect threshold; and iv)stopping movement of the window or panel by controlling an output tosaid switch that controls motor energization if the comparison based ona currently sensed motor parameter indicates the window or panel hascontacted an obstacle.
 20. Apparatus for controlling activation of amotor for moving a window or panel along a travel path and de-activatingthe motor if an obstacle is encountered by the window or panelcomprising: a) a sensor for generating signals representative of thewindow or panel speed as the motor moves the window or panel along atravel path; b) an obstacle detection controller for monitoring at leasta part of the travel path of the window or panel for sensing andgenerating an obstacle detect signal indicating the presence in saidtravel path of an obstacle to movement of the window or panel; c) aswitch coupled to said controller for controlling energization of themotor with an energization signal; and d) said controller includingmeans for processing motor speed and obstacle detection signals andcontrolling operation of the motor in response to said speed or obstacledetection signals; said controller including: i) a storage for storing anumber of speed signals that vary with motor speed; ii) a processor forcalculating an obstacle detect threshold based on one or more speedsignals stored in said storage; iii) a logic unit for making acomparison between a value representing window or panel speed based oncurrently sensed motor speed with a calculated predetermined obstacledetect threshold, and generating a control output based on saidcomparison; and iv) an interface coupled to said switch for changing thestate of the switch to stop the motor.
 21. The apparatus of claim 20wherein the sensor for generating a speed signal comprises a Hall-effectsensor.
 22. The apparatus of claim 20 wherein the sensor for generatinga speed signal comprises a magnetic pick-up.
 23. The apparatus of claim20 additionally comprising an obstacle detector having an output coupledto the controller that senses a disruption in a region through which thewindow or panel moves.
 24. The apparatus of claim 23 wherein theobstacle detector comprises a microwave generator and a reflected wavetransducer.
 25. The apparatus of claim 23 wherein the obstacle detectorcomprises an infrared light source and detector. 27 The apparatus ofclaim 23 wherein the obstacle detector comprises a field effect device.28. The apparatus of claim 27 wherein the field effect device comprisesa magnetic field inductive sensor.